<!--<%'--------------------    HTMLStart Code (Client and Server) ------------------%>-->
<!--<script type="text/javascript">    var top = window.dialogArguments;</script>-->

<script type="text/javascript" src="/components_cb/client/scriptinc_js.htm"></script>

<script type="text/javascript" src="/components_cb/client/scriptinc_nocache_js.htm"></script>

<script type="text/javascript" src="/components_cb/client/htmlstart.min.js"></script>

<!--<%'-------------------------- Server side includes -------------------------%>-->
<!-- #include virtual="/components_cb/client/initDialogEnv_tagged.inc"-->
<!-- #include virtual='/components_cb/server/controls.inc' -->
<!-- #include virtual="/components_cb/server/getrights.inc"-->
<!--<%'-------------------------- Create global Variables ----------------------%>-->

<script type="text/javascript">
    window.returnValue = false;
</script>

<!--<%'-------------------------- Blank XML islands ----------------------%>-->

<script type="text/javascript">
    var otblUsageReport;
    var xmlStorageDetails = NewXmlDOM(false);
    var xmlControls_WATCH_Initialize = NewXmlDOM(false);
    var rootPath = top.ShellAddress.replace("/100", "");
    xmlStorageDetails.loadXML("<StorageDetails />");
    StoreDataXml("xmlStorageDetails", xmlStorageDetails);
</script>

<script type="text/javascript">
    var pageStage = '';
    var LoadData = "0";
    //var sPropID = "0";
    function InitialLoad_Start() {
        var sXMLRequest = "<Page><Request /></Page>";
        InitialLoad_GetData("", top.ShellAddress + "DocumentManagement/ASPX/Setup.aspx/GetStorageReport", sXMLRequest);
    }

    function InitialLoad_onDataReady() {
        InitialLoad_FillXML("StorageDetails", 'xmlStorageDetails', "");
    }

    function InitialLoad_onComplete() {
        Controls_Initialize();
        afterBinding();
        xmlControls_WATCH_Initialize.async = false;
        xmlControls_WATCH_Initialize.loadXML("<Row a='1' />");
        StoreDataXml("xmlControls_WATCH_Initialize", xmlControls_WATCH_Initialize);
        top.resizeDialog(bUsingIframe);
        top.setCustomDialogWidth(830);
        top.setCustomDialogHeight(635);
        top.setActionButtonsPosition(0, 0, window);
    }

    function afterBinding() {
        Controls_WATCH_Initialize();
        Initialize();
    }

    function Initialize() {
        rpiModalHeader.setLoadIndicator(false);
        otblUsageReport.updateTable();
        if ($(xmlStorageDetails).find("Row").length == 0) {
            otblUsageReport.displayMessage("No errors");
        }

    }

    function doClose() {
        window.returnValue = false;
        //window.close();
        top.hideDialog(window.returnValue, window, bUsingIframe);
    }

    function doPrint() {


    }

    function doSupertablePrintCallback() {
        openSupertablePrintModal();
        //window.print();
    }

</script>

<html>
<head>
    <title>OneSite</title>
    <link rel="stylesheet" type="text/css" href="/components_cb/styles/base.min.css" />
    <link rel="stylesheet" type="text/css" href="/components_cb/styles/form.min.css" />
</head>
<% call CreateImports("errorhandling")%>
<% call CreateImports("modalheader")%>
<% call CreateImports("supertable")%>
<body class="datamodal" tabindex="-1" style="overflow: hidden;">
    <div class='RPI_MODALHEADER' id="rpiModalHeader" pagetrail="Document Management - "
        pagelabel="Property Storage Usage Summary" pageid="101.055.100.020">
    </div>
    <br />
    <table id="tblUsageReportHeader" width='800px' cellpadding="0" cellspacing="1" border='0'>
        <tr>
            <td style="font: bold 12pt arial; color: #000000;">
                <nobr>Storage Usage</nobr>
            </td>
        </tr>
    </table>
    <div id="divUsageReport">
        <div class="RPI_SUPERTABLE" id="tblUsageReport" rpdatasource="xmlStorageDetails"
            rpdatanode="StorageDetails" rpheader="true" rpwidth="770px" rpheight="500px"
            rppagesize="30" rpmaxpagelinks='10' rpprint="true">
            <table style="display: none">
                <thead>
                    <tr style='height: 30px;'>
                        <th class="center" style="width: 50px;">
                            <span title="Click to sort" style="color: #ffffff; font-weight: bold;">Site ID</span>
                        </th>
                        <th class="center" style="width: 170px;">
                            <span title="Click to sort" style="color: #ffffff; font-weight: bold;">Site Name</span>
                        </th>
                        <th class="center" style="width: 80px;">
                            <span title="Click to sort" style="color: #ffffff; font-weight: bold;">Storage Used</span>
                        </th>
                        <th class="center" style="width: 80px;">
                            <span title="Click to sort" style="color: #ffffff; font-weight: bold;">Total Allocated</span>
                        </th>
                        <th class="center" style="width: 80px;">
                            <span title="Click to sort" style="color: #ffffff; font-weight: bold;">First Attached
                                Date</span>
                        </th>
                        <th class="center" style="width: 80px;">
                            <span title="Click to sort" style="color: #ffffff; font-weight: bold;">Last Attached
                                Date</span>
                        </th>
                    </tr>
                </thead>
                <tbody>
                    <tr>
                        <td style="text-align: left;" rpdatafld="SiteId" rpnowrap="true" />
                        <td style="text-align: left;" rpdatafld="SiteName" rpnowrap="true" />
                        <td style="text-align: left;" rpdatafld="StorageUsed" rpnowrap="true" />
                        <td style="text-align: left;" rpdatafld="TotalAllocated" rpnowrap="true" />
                        <td style="text-align: left;" rpdatafld="FirstAttachedDate" rpnowrap="true" />
                        <td style="text-align: left;" rpdatafld="LastAttachedDate" rpnowrap="true" />
                    </tr>
                </tbody>
            </table>
        </div>
    </div>
    <div class="IFrameButtons">
        <table id="buttons" border="0">
            <tr>
                <td>
                    <%call Controls_CreateButton("btnPrint","Print","doPrint()","1","","")%>
                </td>
                <td>
                    <%call Controls_CreateButton("btnClose","Close","doClose()","1","","")%>
                </td>
            </tr>
        </table>
    </div>
    <!-- Code to know when binding is done. -->
    <input type="hidden" value="~" datasrc="#xmlControls_WATCH_Initialize" datafld="a"
        onpropertychange="this.onpropertychange='';afterBinding();" id="Hidden1" name="Hidden1" />
</body>

<script type="text/javascript">
    $(window).load(function() {
        InitialLoad_ScreenReady();
        otblUsageReport = $("#tblUsageReport").data("ST");
        InitialLoad_Start();
    });
    var oCBConverted = { 'ie': true, 'firefox': true, 'chrome': true, 'safari': true };   
</script>

</html>
